package com.deft.design.visitor.user;

import com.deft.design.visitor.visitor.Visitor;

/**
 * 基础用户信息
 *
 * @author Hide丶love
 * @date 2022/05/30
 **/
public abstract class User {

    private String name;

    private String identity;

    private String clazz;

    /**
     * 核心访问方法
     * @param visitor 访问者
     */
    public abstract void accept(Visitor visitor);

    public User(String name, String identity, String clazz) {
        this.name = name;
        this.identity = identity;
        this.clazz = clazz;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getIdentity() {
        return identity;
    }

    public void setIdentity(String identity) {
        this.identity = identity;
    }

    public String getClazz() {
        return clazz;
    }

    public void setClazz(String clazz) {
        this.clazz = clazz;
    }
}
